package lab02.test22;

import java.util.Scanner;

/**
 * Created by lenovo on 2017/10/30.
 */
public class Test {
    public static void main(String[] args) {
        String result="你好world2017";
        System.out.println("字符："+result);
        StringBuffer str=new StringBuffer();
        for(int i=0;i<=result.length()-1;i++){
            char ch=result.charAt(i);
            if (ch>='A'&&ch<='Z') {
                ch+='a'-'A';
            }
            else if (ch>='a'&&ch<='z'){
                str.append(ch);
            }
            else if (ch>=49&&ch<=58){
                str.append(0);
            }
            else{
                str.append('#');
            }
        }
        System.out.println( "转换后："+str);
    }
}
